package com.ssm.sfzy.controller;

import com.ssm.sfzy.utils.Result;
import org.springframework.web.bind.annotation.CrossOrigin;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;

/**
 * @ClassName TableController
 * @Author xiaoliu
 * @Date 2024年04月03日 10:44
 */
@RestController
@CrossOrigin
public class TableController {

    @RequestMapping("/getTB")
    public Object getTB(){

        List list = new ArrayList();
        for(int i = 0;i < 5;i ++ ){
            Map map = new HashMap();
            map.put("name","李四" + i);
            map.put("value",20 * i + 20);
            list.add(map);
        }
        return Result.success(list);
    }
}
